<?php
$this->breadcrumbs=array(
	'Inventory Items'=>array('inventory/items'),
	"{$model->code} - {$model->short_description}",
);
?>

<div class="clearb"></div>

<div style="line-height: 24px;" class="span-26 append-1">
	
	<div class="item-header">
		<div class="span-auto append-1"><h2><?php echo $model->code; ?> - <?php echo $model->short_description; ?></h2></div>
	
		<div class="new">
			<span id="edit-link">(<a href="<?php echo $this->createUrl("item/update/id/{$model->id}"); ?>">Edit Item</a>)</span>
		</div>

	</div>
	
	<div class="clearb"></div>

	<div class="description"><?php echo $model->long_description; ?></div>
	
	<div class="content-view">

		<b><?php echo CHtml::encode($model->getAttributeLabel('category_id')); ?>:</b>
		<?php echo CHtml::encode($model->category_id); ?>
		<br />
	
		<b><?php echo CHtml::encode($model->getAttributeLabel('type_id')); ?>:</b>
		<?php echo CHtml::encode($model->type_id); ?>
		<br />
	
		<b>Quantity on Hand:</b> <?php echo $model->quantity; ?> 
		
		<!-- 
		<?php echo CHtml::link('Adjust', '#', array( 'onclick'=>'$("#stockadjustmentwidget").dialog("open"); return false;'))?>

		<?php $this->widget('StockAdjustmentWidget', array('model'=>$model->itemQuantity)); ?>
		
		 -->
		
		<br />
		<b>Cost:</b> <?php echo $model->getCost(); ?>
		<br />
		
	</div>	
	
</div>

<div class="span-11 sidebar roundbottom">
	<div style="padding: 20px 10px; min-height: 200px;">
		<!--  
		<h4 class="sidebar_header quicklinks"><span>Quick Links</span></h4>
		<ul class="links">
			<li><a href=""><span>Item Sales Orders</span></a></li>
			<li><a href=""><span>Item Purchase Orders</span></a></li>
		</ul>
		-->
		<h4 class="sidebar_header reports"><span>Links</span></h4>
		<ul class="links">
			<li><a href="<?php echo $this->createUrl("item/billOfMaterials/itemId/{$model->id}"); ?>"><span>Bill of Materials</span></a></li>
			<li><a href="<?php echo $this->createUrl("item/batches/itemId/{$model->id}"); ?>"><span>Item Batch Details</span></a></li>
		</ul>
		<!-- 
		<h4 class="sidebar_header search"><span>Quick Search</span></h4>
		<ul class="links">
			<li>
				<a href=""><span>All Purchase Orders</span></a>						
				<ul>
					<li><a href=""><span>Outstanding</span></a></li>
					<li><a href=""><span>Completed</span></a></li>
				</ul>
			</li>
			<li>
				<a href=""><span>All Sales Orders</span></a>
				<ul>
					<li><a href=""><span>Outstanding</span></a></li>
					<li><a href=""><span>Completed</span></a></li>
				</ul>						
			</li>
		</ul>
		 -->
	</div>
</div>

<div class="clearb"></div>

<!-- 

<div id="invoice-history">
	<div class="header fs_18">
		<h3>Item History</h3>
	</div>
	<ol class="history-log">

		<li class="first">
			
			<div class="status">
				<span class="neutral">Created</span>
			</div>
			<div class="event-date">21 Mar 2011, 11:56 AM</div>
			<div class="content">
				<p>Created by you.</p>
			</div>
		</li>
		
	</ol>
</div>

 -->



